1. Field of the Invention
The present invention relates generally to the field of imaging systems. More specifically, the present invention relates to a system and method for antialiased imaging of graphical objects on a pixel-oriented display by rasterizing input pixel data as virtual pixels into a memory with a virtual resolution that is higher than the physically displayed pixel resolution.
2. Description of the Related Art
The general approach in antialiasing is known as super sampling and is described in e.g. xe2x80x98Computer Graphicsxe2x80x94Principles and Practicexe2x80x99 second edition by James D. Foley et al, published by Addison-Wesley Publishing Company, Reading Massachusetts 15 US, 1990, ISBN 0-201-12110-7, section 14.10.6.
Antialiasing is used to enhance image quality by reducing certain visible effects, known as xe2x80x98staircasingxe2x80x99. Staircasing is the result of projecting (drawing) objects onto the physical pixels of the display occurring at the boundaries of those projections. A pixel is either replaced with the colour of the object, or it is left unchanged. Antialiasing methods can be xe2x80x98onlinexe2x80x99 or xe2x80x98offlinexe2x80x99. In offline antialiasing several (pre-antialiased) fixed images are stored, which can be reproduced upon request. Although the image quality can be made almost perfect (depending on the tooling that is used), a great disadvantage is that it requires a lot of memory for storage. An additional disadvantage is that there is no flexibility, when it comes to picturing mutually (multiple) overlapping objects (all overlap combinations would have to be prepared up front). Offline antialiasing is applicable only in very specific areas, such as e.g. in displaying pointers of clocks, speedometers, etc and is not suitable for displaying more dynamically varying objects, such as those which occur in the display maps for navigation systems, or in computer related applications, such as e.g. computer games.
The above referenced super sampling approach is usually implemented as an online method, i.e. image antialiasing is being performed online, for example during the process of reading out the image data and sending it to the display. The image is being rasterized (i.e. stored in an image data memory) in subpixels smaller than the display pixels, therewith achieving a higher resolution than the display resolution, hereinafter indicated as normal resolution. This rasterized image is then converted to the normal resolution by combining or averaging the colour values of the subpixels included in the corresponding display pixel, where after the resulting colour is sent to the display. This so-called xe2x80x98super samplingxe2x80x99 method of antialiasing is very demanding with respect to memory capacity (twice the resolution also means four times the amount of memory).
One object of the present invention is to provide a system and method for executing the method for image antialiasing based on super sampling, which compared with the above-known super sampling method uses much less memory capacity and achieves better performance in particular with regard to the flexibility and accuracy of antialiasing.
A method for antialiased imaging of graphical objects on a pixel oriented display by rasterizing input pixel data as virtual pixels into a memory with a virtual resolution that is higher than the physically displayed pixel resolution according to the invention is therefore characterized by several steps. The steps comprise retrieving from the memory an existing colour value of the physical pixel that corresponds to a virtual pixel to be modified, and retrieving from the pixel input data to be rasterized the input colour value of said virtual pixel, by splitting the so retrieved existing and input colour values in basic red, green and blue colour components. Thereafter, the system linearly combines per each colour component the existing and the input colour value and by using the result thereof to overwrite the existing colour value of the physical pixel at the memory location of said physical pixel.
By applying the measures according to the invention, the use of memory capacity is reduced to a minimum in that the virtual pixel input data are being linearly combined with the existing colour value of a physical pixel in an online process before using the result of this linear combination to overwrite the existing colour value of the relevant physical pixel at its original memory location. In this process there is no need for additional memory capacity to store the virtual pixels at double resolution separated from the original colour values of the physical pixels.
Preferably a method according to the invention is characterized in that in linearly combining per each component the existing and the input colour value weighting factors are used, depending on the factor (R) by which the virtual pixel resolution is higher than the physical pixel resolution according to the following algorithm:
((Nxe2x88x921)*existing colour value+M*input colour value)/N, in which M represents a value of at least one and N being R2.
This measure noticeably improves the flexibility and accuracy of the colour definition, needed to minimize the above mentioned visible xe2x80x98staircasingxe2x80x99 effect, resulting from projecting (drawing) objects onto the physical pixels of the display occurring at the boundaries of those projections.
A further preferred method according to the invention is characterized by a repetition of the above algorithm, the number of repetition cycles being determined by the number of virtual pixels being effected with a change in colour value.
This measure further improves the accuracy of the colour definition. In order to make sure that the above algorithm when being applied to all virtual pixels within a certain physical pixel result in a colour substantially identical to the xe2x80x98colour obtained when changing said certain physical pixel directly, M is determined to arrive substantially at the input colour value after completion of the Nth cycle of the algorithm.
This measure results in M being a non-integer number greater than one. When being applied e.g. to a virtual pixel resolution twice the physical resolution, N and M in the above algorithm are to be given the values 4 and 1.463, respectively. However, for execution of the above algorithm in digital form, M is preferably rounded off to a number representing an addition of a number of binary values of 22i in which i is an integer varying between zero and a negative value, depending on the accuracy of M.
Applying this measure to a virtual pixel resolution twice the physical resolution, N and M in the above algorithm are preferably chosen to be 4 and 1.5, respectively.
Applying this measure to a virtual pixel resolution four times the physical resolution, N and M in the above algorithm are preferably chosen to be 16 and 1.5, respectively.
These values significantly simplify digital implementation of the algorithm. The above and other object features and advantages of the present invention will be discussed more in detail hereinafter with reference to the disclosure of preferred embodiments and in particular with reference to the appended figures.